Repository navigation
editorconfig and formatting - #326
Merged
Merged
Conversation
info/Project.xml was an IntelliJ code style scheme (version 173, so IntelliJ 2017.3) that nothing has ever read: the IDE looks for .idea/codeStyles/Project.xml, no such directory exists here, and no build file, workflow or doc referenced it. It was also actively wrong — it declared 2-space Kotlin indentation while the codebase is 4-space throughout, so importing it and reformatting would have rewritten every file. Most of its bulk was Android XML layout attribute-arrangement rules, and the Compose Multiplatform rewrite left exactly two XML files, both manifests. Its one live setting, KOTLIN_OFFICIAL, is already set by kotlin.code.style in gradle.properties. .editorconfig takes its place because IntelliJ, Android Studio, VS Code and ktlint all read it, and it can state the trailing-comma preference rather than leaving it to whoever formats next. .gitattributes pins every text file to LF in the repository, with .bat checked out as CRLF for cmd.exe. It also marks jars, images and fonts binary so no normalisation pass is ever run across them — treating a compressed file as text rewrites bytes inside it and corrupts it silently. kotlin-js-store/wasm/yarn.lock was the only tracked text file still holding CRLF, written that way by yarn on Windows, and is converted here.
A whole-project reformat under the Kotlin official style, plus trailing commas on every multiline parameter and argument list. Both are mechanical: no signature, expression or behaviour changes, which is why it lands in one commit separate from the .editorconfig that now states the rules. Trailing commas are deliberately absent from `if`, `while`, `for` and `catch` parentheses, where Kotlin rejects them — those are not parameter lists.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
No description provided.